package org.example.bean;

/**
 * 懒汉式-线程不安全
 * @author: yh
 * @date: 2022/12/11
 */
public class SingletonLazy {

    private static SingletonLazy uniqueInstance;

    private SingletonLazy() {
    }

    public static SingletonLazy getUniqueInstance() {
        if (uniqueInstance == null) {
            uniqueInstance = new SingletonLazy();
        }
        return uniqueInstance;
    }
}
